"""gcp_tenant

Revision ID: a8dfe40f34a8
Revises: a1d0494e9815
Create Date: 2024-12-05 06:58:44.080681

"""
from alembic import op
import sqlalchemy as sa
from sqlalchemy.dialects import mysql

# revision identifiers, used by Alembic.
revision = 'a8dfe40f34a8'
down_revision = 'a1d0494e9815'
branch_labels = None
depends_on = None

old_cloud_types = sa.Enum('AWS_CNR', 'ALIBABA_CNR', 'AZURE_CNR', 'AZURE_TENANT',
                          'KUBERNETES_CNR', 'ENVIRONMENT', 'GCP_CNR', 'NEBIUS',
                          'DATABRICKS')
new_cloud_types = sa.Enum('AWS_CNR', 'ALIBABA_CNR', 'AZURE_CNR', 'AZURE_TENANT',
                          'KUBERNETES_CNR', 'ENVIRONMENT', 'GCP_CNR',
                          'GCP_TENANT', 'NEBIUS', 'DATABRICKS')


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.alter_column('cloudaccount', 'type', existing_type=old_cloud_types,
                    type_=new_cloud_types, nullable=False)
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.alter_column('cloudaccount', 'type', existing_type=new_cloud_types,
                    type_=old_cloud_types, nullable=False)
    # ### end Alembic commands ###
